//
//  DetailGalleryViewController.m
//  Drops
//
//  Created by dllo on 16/5/23.
//  Copyright © 2016年 Drops.er. All rights reserved.
//

#import "DetailGalleryViewController.h"
#import "MBProgressHUD.h"
@interface DetailGalleryViewController ()
@property(nonatomic, strong)UIWebView *webView;
@property(nonatomic, strong)MBProgressHUD *hud;
@property(nonatomic, strong)NSArray *array;
@end

@implementation DetailGalleryViewController

-(void)viewWillAppear:(BOOL)animated{
     self.hud = [MBProgressHUD showHUDAddedTo:self.view animated:YES];
}
-(void)viewDidAppear:(BOOL)animated{
    [self.hud hide:YES afterDelay:0];
}

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view.
    self.array = [[NSArray alloc]initWithObjects:@"%bc%f2%c6%b4%d3%d7%d6%c9%d4%b0%d6%ae%b3%c9%b3%a4%bc%c7", @"Hello%a3%ac%cf%c4%cc%ec",@"%d6%c2%c7%e0%b4%ba",@"%B6%E0%C8%E2%C2%CC%D6%B2%D3%C6%C8%BB%C5%C9",@"%C3%C8%B3%E8%B8%F8%CE%D2%D6%CE%D3%FA%B5%C4%C1%A6%C1%BF",@"%C5%F3%D3%D1%D1%DB%D6%D0%B5%C4%CE%D2",@"%C3%BB%CA%C2%BE%CD%B3%D4%B3%D4%BA%C8%BA%C8",@"%C9%EE%BE%AE%B1%F9%C9%D9%C5%AE%D7%D4%C5%C4%D0%B4%D5%E6%BC%AF",@"%B1%E4%C3%C0%B1%E4%CA%DD%B1%E4%C5%AE%C9%F1",@"%CE%D2%C3%C7%B5%C4%BA%CF%D5%D5",@"%C2%C3%D0%D0%B5%C4%D2%E2%D2%E5",@"%BC%C7%C2%BC%C9%FA%BB%EE1000%BC%FE%D0%D2%B8%A3%D0%A1%CA%C2", nil];
    self.webView = [[UIWebView alloc]initWithFrame:CGRectMake(0, 0, self.view.frame.size.width, self.view.frame.size.height)];
    NSURLRequest *request = [NSURLRequest requestWithURL:[NSURL URLWithString:[NSString stringWithFormat:@"http://j-world.poco.cn/m.php?r=index/event&title=%@",self.array[self.index]]]];
    [self.view addSubview:self.webView];
    [self.webView loadRequest:request];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
